Next | Prev | Up | Top | Contents | Index

Compatibility and Supported ABIs

With the IRIX 6.2 release on an R8000 system, you can execute programs conforming to any of the following Application Binary Interfaces (ABIs):

Figure 1-1 illustrates the ABIs supported by IRIX 6.2.

[Missing image]

Figure 1-1 : ABIs supported by IRIX 6.2 More specifically, the execution and development environments under IRIX 6.2 provide the following functionality:


Known Compatibility Issues

The following issues are known to cause trouble for 32-bit programs running on IRIX 6.2:

It is possible for a program to determine whether it is running on a 64-bit capable kernel in order to work around the issues listed above. Use sysconf(_SC_KERN_POINTERS), which returns 32 or 64.


Source Level System Interface

The IRIX APIs, as defined in SVID and POSIX, are unchanged. Source code requires no changes to be built -64. The compiled bit sizes of arguments and fields may indeed be different between the 32-bit and 64-bit definitions, but source code should not have to be changed. For example, off_t and size_t are now 64 bits when compiled -64 and 32 bits when compiled -32.

The source code interface to IRIX therefore remains the same, with a few exceptions. This interface is defined by the set of header files in /usr/include. Most of these header files have not changed. The kernel maintains compatibility by converting all system calls from a 32-bit binary into 64-bit internal kernel format. The kernel maintains all states in a superset form (usually 64 bits), converting data structures upon entry to and exit from the kernel. As a result, the kernel continues to keep traditional IRIX form and state information of processes, files, and other structures.


Graphics Environment Support

Table 1-1 summarizes the graphics environments supported under IRIX 6.2. Basically, all of the graphics environments are provided for 32-bit, N32 and 64-bit applications.

IRIX 6.2 Graphics Environment Support
Package32-bit Support64-bit SupportN32 Support
IRIX GL (libgl)YesYesYes
OpenGLYesYesYes
X11R6YesYesYes
Motif1.2.4YesYesYes


Inter-Process Communication

Interfaces across a network connection usually allow 32-bit and 64-bit programs to communicate (for example, NFS works fine). Programs using RPC and XDR should have no problems. Of course, exchanging binary data with size assumptions which do not agree can fail.

Usually, there are no problems with having 32-bit and 64-bit programs interact via system calls. For instance, sending data through a pipe, or sharing file access, or connecting through the network, or shared memory usage, all work. In all cases, however, binary data structure sizes must agree.

Arenas are an exception (see usinit(3)). They are not compatible between 32-bit and 64-bit programs. Arenas can be used within a set of 32-bit programs, and within a set of 64-bit programs, but not across program types. See test_and_set(3) and abilock(3) for locks compatible with 32-bit and 64-bit programs.


Device Driver Interface

The IRIX 6.2 kernel requires MIPS3 or MIPS4 code. MIPS1 drivers cannot be linked. Additionally, the kernel is now linked in ELF format, so the -coff option to link 5.x drivers is no longer used.

The kernel/driver interface (DDI/DKI) has a few changes and some additions. Usually kernel drivers need a lot of rework due to internal assumptions of pointer sizes, page sizes, and I/O mapping sizes.

Socket ioctl() calls to the kernel by 32-bit programs are converted for socket ioctls automatically. Hence, whether a 32-bit or 64-bit program is doing the call makes no difference to the kernel.

Block and character drivers have to be responsible for their own ioctls(). The approach which IRIX drivers follow is to have a single header file for user code compilation, so the driver must convert fields according to differences between the 32-bit and 64-bit compilation models.

For streams, the driver will not know the user process type, so ioctls must be fixed binary data structures. They cannot vary between the 32-bit or 64-bit compilation models. You must fix your header files such that this is true.

Routines have been added to the device kernel interface (DKI) to aid ioctl conversions. Please refer to the IRIX Device Driver Writer's Guide.


Next | Prev | Up | Top | Contents | Index